<template>
  <div class="main">
    <p id="p1">我的云圈<span>(还没有加入云圈)</span></p>
    <div class="d1">
      去云圈广场逛逛<van-icon name="arrow" size="14px" class="fltr" />
    </div>
    <div class="pinglun">
      <div v-for="item in comments" :key="item.actId" class="content">
        <div class="left"><img :src="item.sharePicUrl" alt="" /></div>
        <div class="right">
          <p
            v-text="item.title"
            style="
              font-size: 20px;
              color: green;
              overflow: hidden;
              white-space: nowrap;
              text-overflow: ellipsis;
            "
          ></p>
          <p
            v-text="item.text[0]"
            style="font-size: 14px; margin: 10px 0; color: pink"
          ></p>
          <p v-text="item.text[1]" style="font-size: 14px; color: yellow"></p>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import { getHotTopic } from "../../api/find.js";
export default {
  components: {},
  data() {
    return {
      comments: [],
      limit: 30,
      detail: [],
    };
  },
  computed: {},
  watch: {},

  methods: {
    async loadHotTopic() {
      const result = await getHotTopic({ limit: this.limit });

      console.log(result);
      this.comments = result.data.hot;
      this.detail = result.data.hot.text;
    },
  },
  created() {
    this.loadHotTopic();
  },
  mounted() {},
  beforeCreate() {},
  beforeMount() {},
  beforeUpdate() {},
  updated() {},
};
</script>
<style scoped>
.main {
  background-color: rgb(245, 245, 245);
  /* height: 1000px; */
  padding: 1px;
}
.main #p1 {
  height: 54px;
  line-height: 54px;
  padding-left: 15px;
  font-size: 22px;
  font-weight: 600;
  color: rgb(49, 49, 49);
  margin-top: 15px;
}
.main p span {
  font-size: 12px;
  color: rgb(124, 124, 124);
  font-weight: 400;
  margin-left: 8px;
}
.main .d1 {
  width: 330px;
  height: 60px;
  line-height: 60px;
  margin: 0 auto;
  background-color: rgb(255, 255, 255);
  padding-left: 10px;
  font-size: 18px;
  font-weight: 500;
  position: relative;
  border-radius: 10px;
  margin-bottom: 20px;
}
.main .d1 .fltr {
  position: absolute;
  right: 20px;
  top: 20px;
}
img {
  /* width: 100px; */
  height: 100px;
  display: block;
}
.content {
  display: flex;
  justify-content: space-around;
}
.left {
  width: 100px;
  height: 100px;
}
.right {
  width: 200px;
  height: 200px;
}
</style>